package com.lingshi.yingzaitownmap.service.impl;

import com.lingshi.yingzaitownmap.entity.domain.Category;
import com.lingshi.yingzaitownmap.entity.result.Result;
import com.lingshi.yingzaitownmap.mapper.CategoryMapper;
import com.lingshi.yingzaitownmap.service.CategoryService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
@Slf4j
public class CategoryServiceImpl implements CategoryService {
    @Autowired
    private CategoryMapper categoryMapper;


    @Override
    public List<Category> list() {
        log.info("查询所有分类");
        List<Category> list = categoryMapper.list();
        if (list != null) {
            return list;
        }
        return null;
    }
}
